<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head>
    <meta http-equiv="Content-Type" content="text/html; charset=<?php echo $cfg_soft_lang; ?>" />
    <title>提现 - 会员中心 -
        <?php echo $cfg_webname; ?>
    </title>
    <link href="templets/style/base.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="templets/js/j.js"></script>
    <script type="text/javascript" src="templets/js/load.js"></script>
    <script type="text/javascript" src="templets/js/leftmenu.js"></script>
    <script type="text/javascript" src="templets/js/table_function.js"></script>
    <script type="text/javascript">
        //获得选中文件的文件名
        function GetCheckfolderItem() {
            var allSel = '';
            if (document.form1.deleteid.value) return document.form1.deleteid.value;
            for (i = 0; i < document.form1.deleteid.length; i++) {
                if (document.form1.deleteid[i].checked) {
                    if (allSel == '')
                        allSel = document.form1.deleteid[i].value;
                    else
                        allSel = allSel + "," + document.form1.deleteid[i].value;
                }
            }
            return allSel;
        }

        function DoSubmit() {
            var selid = GetCheckfolderItem();
            if (selid == '') {
                alert("你没选中任何信息！");
                return false;
            }
            if (window.confirm("你确定要删除这些消息么？")) {
                location = "shops_orders.php?dopost=del&ids=" + selid;
            }
        }
    </script>
    <script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script>
</head>

<body>
    <div id="main">
        <?php include(DEDEMEMBER."/templets/head.htm"); ?>
        <div id="content" class="w960 clearfix">
            <?php include(DEDEMEMBER."/templets/menu.php"); ?>
            <div id="mcpmain">
                <div id="appTab">
                    <ul>
                        <li class="thisTab"><a href="#">提现</a></li>
                        <li><a href="eacpay.php?dopost=withdrawallog">提现记录</a></li>
                    </ul>
                </div>
                <div id="mainCp">
                    <!--内容消息提示 -->
                    <h3 class="meTitle">提现</h3>
                    <form action="" method="post">
                        <table>
                            <caption>
                                <tr>
                                    <td width="100px"></td>
                                    <td></td>
                                </tr>

                            </caption>
                            <tr>
                                <td>提现地址：</td>
                                <td> <input type="text" name="cash_address" id="cash_address" value="<?php echo $cash_address;?>" size="64" min-length="30" class="intxt" /></td>
                            </tr>
                            <tr>
                                <td></td>
                                <td>收款地址必填,否则无法提现,请务必填写正确 ,区块链支付后不可逆,不承担由此造成的损失,EACPAY钱包接收生成地址</td>
                            </tr>

                            <?php
							$canCav = intval($cfg_ml->fields['money']);
						?>
                                <tr>
                                    <td>提现：</td>
                                    <td>
                                        <input type="number" name="money" id="cashamount" value="0" onchange="exchangecalcredit()" size="5" min="<?php echo ($canCav >1 ? 1:0);?>" max="<?php echo $canCav;?>" style="width:50px;" class="intxt" /> 个金币
                                        <button type="button" class="button2" onclick="document.getElementById('cashamount').value=<?php echo $canCav;?>;exchangecalcredit();">全部</button>
                                        <span>最大<?php echo $canCav;?>个</span></td>
                                </tr>
                                <tr>
                                    <td>EAC即时价:</td>
                                    <td id="eacas">
                                        <?php echo $exchangeData;?>
                                        <?php echo $bizhong;?>
                                    </td>
                                </tr>
                                <tr>
                                    <td>预计到账:</td>
                                    <td id="eacamount">0 EAC</td>
                                </tr>
                                <tr>
                                    <td></td>
                                    <td><button type="submit" class="button2" style="width: 100px;background-repeat: repeat-x;">申请提现</button></td>
                                </tr>
                                <tr>
                                    <td></td>
                                    <td class="eacpay_remark">
                                        <table width="100%">
                                            <tr>
                                                <td>
                                                    <p>人民币现金 1元 =
                                                        <?php echo round(1/$exchangeData,4);?> EAC</p>
                                                    <p>EACPAY手机端区块链钱包下载:</p>
                                                    <p>1、google play</p>
                                                    <p>2、<a href="http://www.eacpay.com" target="_blank">eacpay.com官网下载</a></p>
                                                    <p>3、手机浏览器扫一扫，下载EACPAY</p>
                                                </td>
                                                <td align="right"><img src="/templets/plus/eacpay/app.jpg" width="160" height="190"/></td>
                                            </tr>
                                        </table>

                                    </td>
                                </tr>
                        </table>
                    </form>
                </div>
                <!--主操作区域 -->
            </div>
        </div>
        <script type="text/javascript">
            jQuery.noConflict();

            var exchangeData = parseFloat('<?php echo $exchangeData;?>');
            var moneybl = parseInt("<?php echo $csetting['moneybl'];?>");


            String.prototype.toInt = function() {
                var s = parseInt(this);
                return isNaN(s) ? 0 : s;
            }

            function exchangecalcredit() {
                cashamount = jQuery('#cashamount');
                cashamount.val(cashamount.val().toInt());
                if (cashamount.val() != 0) {

                    var eac = cashamount.val() / moneybl / exchangeData;
                    eac = eac.toFixed(3);
                    jQuery('#eacamount').text(eac + ' EAC');
                } else {
                    jQuery('#eacamount').text('0 EAC');
                    cashamount.val('0');
                }
            }

            exchangecalcredit();
        </script>
        <?php include(DEDEMEMBER."/templets/foot.htm"); ?>
    </div>
</body>

</html>